<%
	from db_backend import DatabaseInterface
	db = DatabaseInterface()
	data = db.execute_query("select pname from playlist;")
%>
<h3>Information for ${kw['title']}</h3>
			<ul>
				<li>Song Title:&nbsp; ${kw['title']}</li>
				<li>Artist:&nbsp; ${kw['artist']}</li>
				<li>Album:&nbsp; ${kw['album']}</li>
				<li>Genre:&nbsp; ${kw['genre']}</li>
				<li>Filetype:&nbsp; ${kw['filetype']}</li>
				<li>Track Number:&nbsp; ${kw['track']}</li>
				<li>Bit Rate (bps):&nbsp;
				% if kw['bitrate'] == 999999:
					lossless
				% else:
					${kw['bitrate']}
				%endif
				</li>
				<li>Date:&nbsp; ${kw['year']}</li>
				<li>Physical Location:&nbsp; ${kw['location']}</li>
				<li><a href="add_favorite?location=${kw['location']}&title=${kw['title']}&artist=${kw['artist']}&filetype=${kw['filetype']}">Add to favorites?</a></li>
				<li>Add to a playlist?</li>
				<ul>
				%for line in data:
					<li><a href="add_to_playlist?pname=${line[0]}&location=${kw['location']}&artist=${kw['artist']}&filetype=${kw['filetype']}&title=${kw['title']}">${line[0]}</a></li>
				%endfor
				</ul>
			</ul>
